package com.ssy.lingxi.after.sale.api.model.vo.request;

import com.ssy.lingxi.common.model.dto.UserLoginCacheDTO;

import javax.validation.Valid;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Positive;
import javax.validation.constraints.Size;
import java.io.Serializable;
import java.util.List;

/**
 * 收货换货新增入库单VO
 * @author 伍将
 * @date 2020/9/18
 * @version 2.0.0
 */
public class ReplaceAddStorageVO implements Serializable {
    private static final long serialVersionUID = -578097508491571137L;

    /**
     * 换货id
     */
    @NotNull(message = "换货Id要大于0")
    @Positive(message = "换货Id要大于0")
    private Long replaceId;

    /**
     * 入库单id
     */
    @NotNull(message = "入库单Id要大于0")
    @Positive(message = "入库单Id要大于0")
    private Long storageId;

    /**
     * 入库单号
     */
    @NotBlank(message = "入库单号不能为空")
    private String storageNo;

    /**
     * 入库时间
     */
    @NotNull(message = "入库时间不能为空")
    private Long storageTime;

    /**
     * 商品列表
     */
    @Valid
    @NotNull(message = "商品不能为空")
    @Size(min = 1, message = "至少有一个商品")
    private List<ReplaceAddGoodsDetailVO> detailList;

    /**
     * 操作会员
     */
//    @NotNull(message = "操作会员不能为空")
//    @Valid
    private UserLoginCacheDTO member;

    public UserLoginCacheDTO getMember() {
        return member;
    }

    public void setMember(UserLoginCacheDTO member) {
        this.member = member;
    }

    public Long getStorageId() {
        return storageId;
    }

    public void setStorageId(Long storageId) {
        this.storageId = storageId;
    }

    public Long getStorageTime() {
        return storageTime;
    }

    public void setStorageTime(Long storageTime) {
        this.storageTime = storageTime;
    }

    public List<ReplaceAddGoodsDetailVO> getDetailList() {
        return detailList;
    }

    public void setDetailList(List<ReplaceAddGoodsDetailVO> detailList) {
        this.detailList = detailList;
    }

    public Long getReplaceId() {
        return replaceId;
    }

    public void setReplaceId(Long replaceId) {
        this.replaceId = replaceId;
    }

    public String getStorageNo() {
        return storageNo;
    }

    public void setStorageNo(String storageNo) {
        this.storageNo = storageNo;
    }
}
